<!DOCTYPE html>
<html lang="zh">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>时间轴</title>
    <link href="../static/css/bootstrap.min.css" th:href="@{/css/bootstrap.min.css}" rel="stylesheet"/>
    <link href="../static/css/font-awesome.min.css" th:href="@{/css/font-awesome.min.css}" rel="stylesheet"/>
    <link href="../static/css/main/animate.min.css" th:href="@{/css/main/animate.min.css}" rel="stylesheet"/>
    <link th:href="@{/css/style.css}" rel="stylesheet"/>
</head>
<body class="gray-bg">
<div class="row animated fadeInRight">
    <div class="ibox float-e-margins">
        <div class="text-center float-e-margins p-md">
            <h2>欢迎来到勤工助学管理系统</h2>
           <!-- <span>打开/关闭颜色/背景或方向版本: </span>
            <a href="#" class="btn btn-xs btn-primary" id="lightVersion">轻型版本 </a>
            <a href="#" class="btn btn-xs btn-primary" id="darkVersion">黑色版本 </a>-->
        </div>
        <div id="ibox-content">
            <div id="vertical-timeline" class="vertical-container light-timeline">
                <div class="vertical-timeline-block">
                    <div class="vertical-timeline-icon blue-bg">
                        <i class="fa fa-file-text"></i>
                    </div>

                    <div class="vertical-timeline-content">
                        <h2>个人信息</h2>
                        <p>初次登陆请及时修改个人密码并完善个人详细信息，有问题请联系后台管理员 0310666</p>
                        <a  class="btn btn-sm btn-success" onclick="person()"> 个人信息 </a>
                        <!--<span class="vertical-date">
                         	今天 <br>
                         <small>2月3日</small>
                     </span>-->
                    </div>
                </div>
                <div class="vertical-timeline-block">
                    <div class="vertical-timeline-icon navy-bg">
                        <i class="fa fa-briefcase"></i>
                    </div>

                    <div class="vertical-timeline-content">
                        <h2>消息</h2>
                        <p>及时查看站内消息，关注最新动态内容。
                        </p>
                        <a class="btn btn-sm btn-primary" onclick="message()"> 更多信息</a>
                        <!--<span class="vertical-date">
                         	今天 <br>
                         <small>2月3日</small>-->
                     </span>
                    </div>
                </div>
                <div class="vertical-timeline-block">
                    <div class="vertical-timeline-icon lazur-bg">
                        <i class="fa fa-user-md"></i>
                    </div>

                    <div class="vertical-timeline-content">
                        <h2>信用机制</h2>
                        <p>为鼓励学生积极参加工作岗位，实施信用分数机制，通过学生榜展示优秀的学生。</p>
                        <!--<span class="vertical-date">前天 <br><small>2月1日</small></span>-->
                        <a href="#" class="btn btn-sm btn-info" onclick="studentScore()">学生榜 </a>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<th:block th:include="include :: footer" />
<script>
    $(document).ready(function(){
        setPersonMessage()
        function setPersonMessage(){
            let url = '/wstudy/student/query'
            let params = {   }
            $.ajax({
                type:'post',
                jsonType:"json",
                url:url,
                data:params,
                async:"false",
                success:function (result) {
                    if (result.msg=='yes' ){
                        $.modal.confirm("请您完善个人信息！",function () {
                            setStudentMessagePage()
                        });
                    }
                }
            })
        }
        function setStudentMessagePage() {
            let url = '/wstudy/student/info'
            $.modal.openTab("完善个人信息",url);
        }
        $('#lightVersion').click(function(event) {
            event.preventDefault()
            $('#ibox-content').removeClass('ibox-content');
            $('#vertical-timeline').removeClass('dark-timeline');
            $('#vertical-timeline').addClass('light-timeline');
        });
        $('#darkVersion').click(function(event) {
            event.preventDefault()
            $('#ibox-content').addClass('ibox-content');
            $('#vertical-timeline').removeClass('light-timeline');
            $('#vertical-timeline').addClass('dark-timeline');
        });
    });
    function person() {
        $.modal.openTab("个人信息","/system/user/profile")
    }
    function message() {
        $.modal.openTab("消息","/wstudy/message")
    }
    function studentScore() {
        $.modal.openTab("学生榜","/wstudy/summary/studentSummary")
    }
</script>
</body>
</html>